using Castle.MicroKernel.Registration;
using Castle.Windsor;
using NHibernate;
using ThunderJob.Bootstrapper.Dependency;
using ThunderJob.Persistence;
using System.Web;

namespace ThunderJob.Bootstrapper.Configuration
{
    public class NHibernateConfiguration : IConfigurationTask
    {
        private const string ConfigFile = "NHibernate.config";

        public void Configure()
        {
            NHibernateSession.Init(HttpContext.Current.Server.MapPath(ConfigFile),SessionContext.Web);
        }
    }
}